<%@ page language="java" pageEncoding="utf-8"%>
<html>
	<head>
		<title>管理系统</title>
		<link rel="stylesheet" type="text/css" href="../ext/ext-all.css" />
		<script type="text/javascript" src="../ext/ext-base.js"></script>
		<script type="text/javascript" src="../ext/ext-all.js"></script>
<style type="text/css">
.settings {
	background: url(../img/menu.png) left top no-repeat !important;
}
</style>
<script type="text/javascript">
Ext.BLANK_IMAGE_URL = '../images/s.gif';
</script>
	</head>
	<body >
		<div id="loading-mask" style=""></div>
		<div id="loading">

			<script type="text/javascript">
			//生成标签页

			var tab = new Ext.TabPanel({
			region:'center',
			deferredRender:false,
			activeTab:0,
			resizeTabs:true, // turn on tab resizing
			minTabWidth: 115,
			tabWidth:135,
			enableTabScroll:true
		});

Ext.onReady(function(){
   //layout
   var viewport = new Ext.Viewport({
		layout:'border',
		items:[

			new Ext.BoxComponent({
				region:'north',
				layout:'border',
				el: 'north1',
				height:50,
				items:[
				 new Ext.Button({
				 text:'确定'
				 })

				]
			}),new Ext.BoxComponent({
				region:'south',
				el: 'south',
				height:25
			}),{

			region:'west',
			id:'west-panel',
			split:true,
			width: 200,
			minSize: 175,
			maxSize: 400,
			margins:'0 0 0 0',
			layout:'accordion',
			title:'短信管理系统',
			collapsible :true,
			layoutConfig:{
				animate:true
				},
		    items: [
			    {
					title:'下级代理管理',
					border:false,
					html:'<div id="tree1" style="overflow:auto;width:100%;height:100%"></div>',
					iconCls:'settings'
			    },{
					title:'通道管理',
					border:false,
					iconCls:'settings',
					html:'<div id="tree3" style="overflow:auto;width:100%;height:100%"></div>'
			    },{
					title:'短信管理',
					border:false,
					iconCls:'settings',
					html:'<div id="tree5" style="overflow:auto;width:100%;height:100%"></div>'
			    },{
					title:'系统管理',
					border:false,
					iconCls:'settings',
					html:'<div id="tree6" style="overflow:auto;width:100%;height:100%"></div>'
			    }


			    ]
			},
	        tab//初始标签页
		 ]
	});


//--------------下级代理管理----------

    var root1=new Ext.tree.TreeNode({
		    id:"root1",
		    text:"树的根"
		});

	var root1_1=new Ext.tree.TreeNode({
		id:'root1_1',
		icon:'../img/im2.png',
		text:'代理注册',
		listeners:{
        'click':function(node, event) {
            event.stopEvent();
            var n = tab.getComponent(node.id);
            if (!n) { //判断是否已经打开该面板
                 n = tab.add({
                    'id':node.id,
                    'title':node.text,
                     closable:true,  //通过html载入目标页
                     html:'<iframe scrolling="auto" frameborder="0" width="100%" height="100%" src="proxyregdit.jsp"></iframe>'
                 });
             }
             tab.setActiveTab(n);
         }
		}
	});

    var root1_2=new Ext.tree.TreeNode({
		id:'root1_2',
		icon:'../img/im2.png',
		text:'代理管理',
		    listeners:{
        'click':function(node, event) {
            event.stopEvent();
            var n = tab.getComponent(node.id);
            if (!n) { //判断是否已经打开该面板
                 n = tab.add({
                    'id':node.id,
                    'title':node.text,
                     closable:true,  //通过html载入目标页
                     html:'<iframe scrolling="auto" frameborder="0" width="100%" height="100%" src="editorproxy.jsp"></iframe>'
                 });
             }
             tab.setActiveTab(n);
         }
		}
	});

	root1.appendChild(root1_1);
	root1.appendChild(root1_2);

   var tree1=new Ext.tree.TreePanel({
		renderTo:"tree1",
		root:root1,
		animate:true,
		enableDD:false,
		border:false,
		rootVisible:false,
		containerScroll: true
	});
//-----------------------end------------------

//---------------通道管理---------------------
		    var root3=new Ext.tree.TreeNode({
		    id:"root3",
		    text:"树的根"
		});

	var root3_1=new Ext.tree.TreeNode({
		id:'root3_1',
		icon:'../img/im2.png',
		text:'通道注册',
		listeners:{
        'click':function(node, event) {
            event.stopEvent();
            var n = tab.getComponent(node.id);
            if (!n) { //判断是否已经打开该面板
                 n = tab.add({
                    'id':node.id,
                    'title':node.text,
                     closable:true,  //通过html载入目标页
                     html:'<iframe scrolling="auto" frameborder="0" width="100%" height="100%" src="channelregdit.jsp"></iframe>'
                 });
             }
             tab.setActiveTab(n);
         }
		}
	});

    var root3_2=new Ext.tree.TreeNode({
		id:'root3_3',
		icon:'../img/im2.png',
		text:'通道管理',
		    listeners:{
        'click':function(node, event) {
            event.stopEvent();
            var n = tab.getComponent(node.id);
            if (!n) { //判断是否已经打开该面板
                 n = tab.add({
                    'id':node.id,
                    'title':node.text,
                     closable:true,  //通过html载入目标页
                     html:'<iframe scrolling="auto" frameborder="0" width="100%" height="100%" src="channeleditor.jsp"></iframe>'
                 });
             }
             tab.setActiveTab(n);
         }
		}
	});

    var root3_3=new Ext.tree.TreeNode({
		id:'root3_2',
		icon:'../img/im2.png',
		text:'通道变更',
		    listeners:{
        'click':function(node, event) {
            event.stopEvent();
            var n = tab.getComponent(node.id);
            if (!n) { //判断是否已经打开该面板
                 n = tab.add({
                    'id':node.id,
                    'title':node.text,
                     closable:true,  //通过html载入目标页
                     html:'<iframe scrolling="auto" frameborder="0" width="100%" height="100%" src="changechannel.jsp"></iframe>'
                 });
             }
             tab.setActiveTab(n);
         }
		}
	});

	root3.appendChild(root3_1);
	root3.appendChild(root3_2);
	root3.appendChild(root3_3);

		var tree3=new Ext.tree.TreePanel({
		renderTo:"tree3",
		root:root3,    //对应 根节点
		animate:true,
		enableDD:false,
		border:false,
		rootVisible:false,
		containerScroll: true
		});
//---------------------------------------

//----------短信管理---------------------------
		var root5=new Ext.tree.TreeNode({
		    id:"root4",
		    text:"树的根"
		});

	var root5_1=new Ext.tree.TreeNode({
		id:'root5_1',
		icon:'../img/im2.png',
		text:'发送监控',
		listeners:{
        'click':function(node, event) {
            event.stopEvent();
            var n = tab.getComponent(node.id);
            if (!n) { //判断是否已经打开该面板
                 n = tab.add({
                    'id':node.id,
                    'title':node.text,
                     closable:true,  //通过html载入目标页
                     html:'<iframe scrolling="auto" frameborder="0" width="100%" height="100%" src="messagestatu.jsp"></iframe>'
                 });
             }
             tab.setActiveTab(n);
         }
		}
	});

    var root5_2=new Ext.tree.TreeNode({
		id:'root5_2',
		icon:'../img/im2.png',
		text:'信息管理',
		    listeners:{
        'click':function(node, event) {
            event.stopEvent();
            var n = tab.getComponent(node.id);
            if (!n) { //判断是否已经打开该面板
                 n = tab.add({
                    'id':node.id,
                    'title':node.text,
                     closable:true,  //通过html载入目标页
                     html:'<iframe scrolling="auto" frameborder="0" width="100%" height="100%" src="messagemanage.jsp"></iframe>'
                 });
             }
             tab.setActiveTab(n);
         }
		}
	});

	root5.appendChild(root5_1);
	root5.appendChild(root5_2);

		var tree5=new Ext.tree.TreePanel({
		renderTo:"tree5",
		root:root5,    //对应 根节点
		animate:true,
		enableDD:false,
		border:false,
		rootVisible:false,
		containerScroll: true
	});

//-------------系统管理------------

var root6=new Ext.tree.TreeNode({
		    id:"root4",
		    text:"树的根"
		});

	var root6_1=new Ext.tree.TreeNode({
		id:'root6_1',
		icon:'../img/im2.png',
		text:'系统管理菜单一',
		listeners:{
        'click':function(node, event) {
            event.stopEvent();
            var n = tab.getComponent(node.id);
            if (!n) { //判断是否已经打开该面板
                 n = tab.add({
                    'id':node.id,
                    'title':node.text,
                     closable:true,  //通过html载入目标页
                     html:'<iframe scrolling="auto" frameborder="0" width="100%" height="100%" src="system.jsp"></iframe>'
                 });
             }
             tab.setActiveTab(n);
         }
		}
	});


	root6.appendChild(root6_1);

		var tree6=new Ext.tree.TreePanel({
		renderTo:"tree6",
		root:root6,    //对应 根节点
		animate:true,
		enableDD:false,
		border:false,
		rootVisible:false,
		containerScroll: true
	});
});
			</script>
			   <div id="north1">
				<p class="api-title">
					<b>飞网短信业务管理系统</b>
				</p>
				<div align="right"><a href='../ajaxjsp/logout.jsp'>退出</a></div>
			</div>

			<div id="west">
			</div>
			<div id="south">
				<div
					style="float: left; margin: 5px; font: normal 12px tahoma, arial, sans-serif, 宋体;">
					Power By: lrf & lm
					<span style="color: blue">管理系统</span> &nbsp;
				</div>
				<div
					style="float: right; margin: 5px; font: normal 12px tahoma, arial, sans-serif, 宋体;">
					版权所有：飞网短信业务管理系统
				</div>
			</div>

		</div>
	</body>
</html>
